package converters;

import org.springframework.core.convert.converter.Converter;
import org.springframework.stereotype.Component;
import org.springframework.transaction.annotation.Transactional;

import domain.WorkUpdate;

@Component
@Transactional
public class WorkUpdateToStringConverter implements Converter<WorkUpdate, String>{

	@Override
	public String convert(WorkUpdate workUpdate) {
	String result;

	if (workUpdate == null)
		result = null;
	else
		result = String.valueOf(workUpdate.getId());

	return result;
}

}
